import request from '@/utils/request'
// 获取额点回路下拉列表
export const cdhlxialaapi = () => request.get('/core/dictionary/combo-item/list?dictType=MeasureLoop')
// 获取测点模板列表
export const getmubanlistapi = params => request.get('/core/iot/config/item-template/list', { params })
// 新增批量添加接口
// export const postpiliangapi = data => request.post('/iot/config/item-template', { ...data, isParams: true })
export const postpiliangapi = data => request.post(`/core/iot/config/item-template?meterType=${data.meterType}&itemLoop=${data.itemLoop}&itemTag=${data.itemTag}`)
// 批量停用接口
export const postpiltingapi = data => request.post(`/core/iot/config/item-template/disabled?id=${data}`)
// 批量启用接口
export const postpilqiapi = data => request.post(`/core/iot/config/item-template/enabled?id=${data}`)
// 批量删除接口
export const delpiliangapi = data => request.post(`/core/iot/config/item-template/delete?id=${data}`)
// 获取批量修改测点模板
export const getpicedianlistapi = data => request.get(`/core/iot/config/item-template/batch-edit/list?id=${data}`)
// 获取遥测事件下拉框
export const getyaocexialaapi = () => request.get('/core/iot/config/event-type/analog/combo-items')
// 批量修改接口
export const postpiliangputapi = data => request.post('/core/iot/config/item-template/batch-edit', data)
// 获取遥测事件下拉框
export const getyaoxinxialaapi = () => request.get('/core/iot/config/event-type/discrete/combo-items')
// 添加枚举
export const putmeijuapi = data => request.post('/core/iot/config/item-template/enum-item/put', { ...data, isParams: true })
// 删除枚举
export const delmeijuapi = data => request.post('/core/iot/config/item-template/enum-item/delete', { ...data, isParams: true })
// 获取控制模式下拉菜单
export const getkongzhiapi = () => request.get('/core/dictionary/combo-item/list?dictType=ControlMode')
// 批量复制新增接口
export const postfuzhiapi = data => request.post(`/core/iot/config/item-template/refer-to?copyFromMeterType=${data.copyFromMeterType}&meterType=${data.meterType}`)
// 批量修改设备测点
export const postpixiucedianapi = data => request.get(`/core/iot/config/device-item/batch-edit/list?id=${data}`)
// 获取遥信下拉
export const getyaoxinxialapi = () => request.get('/core/dictionary/combo-item/list?dictType=AlarmMask')
// 查询分页数据
export const getTemplateListapi=params=>request.get('/core/iot/config/item-template/page',{params})
